package com.zhongge.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;

import java.time.LocalDateTime;

/**
 * @ClassName Student
 * @Description TODO
 * @Author zhongge
 * @Version 1.0
 */
public class Student {
    private Integer id;//学生编号
    private String studentNo;//学号
    private String name;//学生姓名
    private Integer age;//年龄
    private String gender;//性别

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")//格式化
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") // 与前端传递的格式一致
    private LocalDateTime birthday;//出生日期

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getStudentNo() {
        return studentNo;
    }

    public void setStudentNo(String studentNo) {
        this.studentNo = studentNo;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getAge() {
        return age;
    }

    public void setAge(Integer age) {
        this.age = age;
    }

    public String getGender() {
        return gender;
    }

    public void setGender(String gender) {
        this.gender = gender;
    }

    public LocalDateTime getBirthday() {
        return birthday;
    }

    public void setBirthday(LocalDateTime birthday) {
        this.birthday = birthday;
    }
}
